Optimal. Leaf size=150 \[ -\frac {2 (A b-a B) \sqrt {\frac {b+a \cos (c+d x)}{a+b}} F\left (\frac {1}{2} (c+d x)|\frac {2 a}{a+b}\right ) \sqrt {\sec (c+d x)}}{a d \sqrt {a+b \sec (c+d x)}}+\frac {2 A E\left (\frac {1}{2} (c+d x)|\frac {2 a}{a+b}\right ) \sqrt {a+b \sec (c+d x)}}{a d \sqrt {\frac {b+a \cos (c+d x)}{a+b}} \sqrt {\sec (c+d x)}} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.20, antiderivative size = 150, normalized size of antiderivative = 1.00, number of steps
used = 7, number of rules used = 7, integrand size = 35, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.200, Rules used = {4120, 3941,
2734, 2732, 3943, 2742, 2740} \begin {gather*} \frac {2 A \sqrt {a+b \sec (c+d x)} E\left (\frac {1}{2} (c+d x)|\frac {2 a}{a+b}\right )}{a d \sqrt {\sec (c+d x)} \sqrt {\frac {a \cos (c+d x)+b}{a+b}}}-\frac {2 (A b-a B) \sqrt {\sec (c+d x)} \sqrt {\frac {a \cos (c+d x)+b}{a+b}} F\left (\frac {1}{2} (c+d x)|\frac {2 a}{a+b}\right )}{a d \sqrt {a+b \sec (c+d x)}} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 2732
Rule 2734
Rule 2740
Rule 2742
Rule 3941
Rule 3943
Rule 4120
Rubi steps
\begin {align*} \int \frac {A+B \sec (c+d x)}{\sqrt {\sec (c+d x)} \sqrt {a+b \sec (c+d x)}} \, dx &=\frac {A \int \frac {\sqrt {a+b \sec (c+d x)}}{\sqrt {\sec (c+d x)}} \, dx}{a}-\frac {(A b-a B) \int \frac {\sqrt {\sec (c+d x)}}{\sqrt {a+b \sec (c+d x)}} \, dx}{a}\\ &=-\frac {\left ((A b-a B) \sqrt {b+a \cos (c+d x)} \sqrt {\sec (c+d x)}\right ) \int \frac {1}{\sqrt {b+a \cos (c+d x)}} \, dx}{a \sqrt {a+b \sec (c+d x)}}+\frac {\left (A \sqrt {a+b \sec (c+d x)}\right ) \int \sqrt {b+a \cos (c+d x)} \, dx}{a \sqrt {b+a \cos (c+d x)} \sqrt {\sec (c+d x)}}\\ &=-\frac {\left ((A b-a B) \sqrt {\frac {b+a \cos (c+d x)}{a+b}} \sqrt {\sec (c+d x)}\right ) \int \frac {1}{\sqrt {\frac {b}{a+b}+\frac {a \cos (c+d x)}{a+b}}} \, dx}{a \sqrt {a+b \sec (c+d x)}}+\frac {\left (A \sqrt {a+b \sec (c+d x)}\right ) \int \sqrt {\frac {b}{a+b}+\frac {a \cos (c+d x)}{a+b}} \, dx}{a \sqrt {\frac {b+a \cos (c+d x)}{a+b}} \sqrt {\sec (c+d x)}}\\ &=-\frac {2 (A b-a B) \sqrt {\frac {b+a \cos (c+d x)}{a+b}} F\left (\frac {1}{2} (c+d x)|\frac {2 a}{a+b}\right ) \sqrt {\sec (c+d x)}}{a d \sqrt {a+b \sec (c+d x)}}+\frac {2 A E\left (\frac {1}{2} (c+d x)|\frac {2 a}{a+b}\right ) \sqrt {a+b \sec (c+d x)}}{a d \sqrt {\frac {b+a \cos (c+d x)}{a+b}} \sqrt {\sec (c+d x)}}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 3.78, size = 103, normalized size = 0.69 \begin {gather*} \frac {2 \sqrt {\frac {b+a \cos (c+d x)}{a+b}} \left (A (a+b) E\left (\frac {1}{2} (c+d x)|\frac {2 a}{a+b}\right )+(-A b+a B) F\left (\frac {1}{2} (c+d x)|\frac {2 a}{a+b}\right )\right ) \sqrt {\sec (c+d x)}}{a d \sqrt {a+b \sec (c+d x)}} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [B] Leaf count of result is larger than twice the leaf count of optimal. \(939\) vs.
\(2(196)=392\).
time = 14.08, size = 940, normalized size = 6.27 Too large to display
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Failed to integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [C] Result contains higher order function than in optimal. Order 9 vs. order
4.
time = 0.86, size = 371, normalized size = 2.47 \begin {gather*} \frac {3 i \, \sqrt {2} A a^{\frac {3}{2}} {\rm weierstrassZeta}\left (-\frac {4 \, {\left (3 \, a^{2} - 4 \, b^{2}\right )}}{3 \, a^{2}}, \frac {8 \, {\left (9 \, a^{2} b - 8 \, b^{3}\right )}}{27 \, a^{3}}, {\rm weierstrassPInverse}\left (-\frac {4 \, {\left (3 \, a^{2} - 4 \, b^{2}\right )}}{3 \, a^{2}}, \frac {8 \, {\left (9 \, a^{2} b - 8 \, b^{3}\right )}}{27 \, a^{3}}, \frac {3 \, a \cos \left (d x + c\right ) + 3 i \, a \sin \left (d x + c\right ) + 2 \, b}{3 \, a}\right )\right ) - 3 i \, \sqrt {2} A a^{\frac {3}{2}} {\rm weierstrassZeta}\left (-\frac {4 \, {\left (3 \, a^{2} - 4 \, b^{2}\right )}}{3 \, a^{2}}, \frac {8 \, {\left (9 \, a^{2} b - 8 \, b^{3}\right )}}{27 \, a^{3}}, {\rm weierstrassPInverse}\left (-\frac {4 \, {\left (3 \, a^{2} - 4 \, b^{2}\right )}}{3 \, a^{2}}, \frac {8 \, {\left (9 \, a^{2} b - 8 \, b^{3}\right )}}{27 \, a^{3}}, \frac {3 \, a \cos \left (d x + c\right ) - 3 i \, a \sin \left (d x + c\right ) + 2 \, b}{3 \, a}\right )\right ) + \sqrt {2} {\left (-3 i \, B a + 2 i \, A b\right )} \sqrt {a} {\rm weierstrassPInverse}\left (-\frac {4 \, {\left (3 \, a^{2} - 4 \, b^{2}\right )}}{3 \, a^{2}}, \frac {8 \, {\left (9 \, a^{2} b - 8 \, b^{3}\right )}}{27 \, a^{3}}, \frac {3 \, a \cos \left (d x + c\right ) + 3 i \, a \sin \left (d x + c\right ) + 2 \, b}{3 \, a}\right ) + \sqrt {2} {\left (3 i \, B a - 2 i \, A b\right )} \sqrt {a} {\rm weierstrassPInverse}\left (-\frac {4 \, {\left (3 \, a^{2} - 4 \, b^{2}\right )}}{3 \, a^{2}}, \frac {8 \, {\left (9 \, a^{2} b - 8 \, b^{3}\right )}}{27 \, a^{3}}, \frac {3 \, a \cos \left (d x + c\right ) - 3 i \, a \sin \left (d x + c\right ) + 2 \, b}{3 \, a}\right )}{3 \, a^{2} d} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \int \frac {A + B \sec {\left (c + d x \right )}}{\sqrt {a + b \sec {\left (c + d x \right )}} \sqrt {\sec {\left (c + d x \right )}}}\, dx \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [F]
time = 0.00, size = -1, normalized size = -0.01 \begin {gather*} \int \frac {A+\frac {B}{\cos \left (c+d\,x\right )}}{\sqrt {a+\frac {b}{\cos \left (c+d\,x\right )}}\,\sqrt {\frac {1}{\cos \left (c+d\,x\right )}}} \,d x \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________